﻿<%@ Page Language="C#" MasterPageFile="~/FrameMasterPage.master" AutoEventWireup="true" CodeFile="pcSparepartAdd.aspx.cs" Inherits="pcSparepartAdd" Title="Untitled Page" %>

<asp:Content ID="Content1" ContentPlaceHolderID="m_contentBody" Runat="Server">
<body>
<asp:Label ID="lblMessageValidate" runat="server" CssClass="permissionstyle"></asp:Label>
<asp:Panel ID="pnlBody" runat="server">

        <table  cellspacing="2" cellpadding ="2" style="height:100%" class="GridItem" >
       
        <tr style="text-align:center">
        <td  colspan="4"  class="BigLabelLeftAlign"> Computer &#39;s detail information<br />
            </td>
        </tr>
      <tr>
         <td style="width: 249px" >
             VGA model</td>
         <td style="width: 233px" >
             <br />
         <asp:DropDownList ID="drlVGA" runat="server"  Width="184px" 
                 AppendDataBoundItems="True" EnableTheming="False" 
                  
                 DataTextField="model" 
                  Height="25px" DataSourceID="odsDepartment" DataValueField="modelId">
             <asp:ListItem Value="-1">--Choose VGA Model--</asp:ListItem>
         </asp:DropDownList>
             <asp:ObjectDataSource ID="odsDepartment" runat="server" 
                 SelectMethod="GetVGAModel" TypeName="ReferenceDataDirectService" 
                 OldValuesParameterFormatString="original_{0}">
             </asp:ObjectDataSource>
          &nbsp;
                                                <asp:Label ID="lblRequiredDepartment" runat="server" ForeColor="Red" Visible="False"></asp:Label>
         </td>
           <td style="height: 28px; width: 238px;">VGA Size (MB)</td>
         <td style="height: 28px">
         <asp:TextBox  ID="txtVGA" runat="server" Width="120px"  >
         </asp:TextBox>
         </td>
      </tr>
     
      <tr>
         <td style="height: 28px; width: 249px;">RAM model</td>
         <td style="height: 28px; width: 233px;">
         <asp:DropDownList ID="drlRAM" runat="server"  Width="184px" 
                 AppendDataBoundItems="True"  DataTextField="model" 
                  Height="25px" DataSourceID="odsCompany" DataValueField="modelId">
             <asp:ListItem Value="-1">--Choose RAM model--</asp:ListItem>
         </asp:DropDownList>
             <asp:ObjectDataSource ID="odsCompany" runat="server" 
                 SelectMethod="GetRamModel" TypeName="ReferenceDataDirectService">
             </asp:ObjectDataSource>
          &nbsp;
                                                <asp:Label ID="lblRequiredCompany" runat="server" ForeColor="Red" Visible="False"></asp:Label>
         </td>
         <td style="width: 100px">RAM Size (MB)</td>
         <td>
         <asp:TextBox  ID="txtRAM" runat="server" Width="120px"  >
         </asp:TextBox>
         </td>
      </tr>
      
      <tr>
      <td style="height: 28px; width: 249px;">Sound card model</td>
         <td style="height: 28px; width: 233px;">
         <asp:DropDownList ID="drlSound" runat="server"  Width="184px" 
                 AppendDataBoundItems="True" DataSourceID="odsGroup" 
                 DataValueField="modelId" DataTextField="model"  Height="25px">
             <asp:ListItem Value="-1">--Choose Sound card model--</asp:ListItem>
         </asp:DropDownList>
             <asp:ObjectDataSource ID="odsGroup" runat="server" SelectMethod="GetSoundCardModel" 
                 TypeName="ReferenceDataDirectService"></asp:ObjectDataSource>
             &nbsp;
                                                <asp:Label ID="lblRequiredGroup" runat="server" ForeColor="Red" Visible="False"></asp:Label>
            
         </td>
         <td colspan="2"></td>
      </tr>
      <tr>
       <td style="height: 28px; width: 249px;">CPU model</td>
         <td style="height: 28px; width: 233px;">
         <asp:DropDownList ID="drlCPU" runat="server"  Width="184px" 
                 AppendDataBoundItems="True" DataSourceID="odsCPU" 
                 DataValueField="modelId" DataTextField="model"  Height="25px">
             <asp:ListItem Value="-1">--Choose CPU model--</asp:ListItem>
         </asp:DropDownList>
             <asp:ObjectDataSource ID="odsCPU" runat="server" SelectMethod="GetCPUModel" 
                 TypeName="ReferenceDataDirectService"></asp:ObjectDataSource>
             &nbsp;
                                                <asp:Label ID="Label1" runat="server" ForeColor="Red" Visible="False"></asp:Label>
            
         </td>
          <td style="width: 100px"> CPU Speed (MHz)</td>
         <td>
         <asp:TextBox  ID="txtCPU" runat="server" Width="120px"  >
         </asp:TextBox>
         </td>
      </tr>
     
      <tr>
      <td style="height: 28px; width: 249px;"> Hardisk model</td>
         <td style="height: 28px; width: 233px;">
         <asp:DropDownList ID="drlHardisk" runat="server"  Width="184px" 
                 AppendDataBoundItems="True" DataSourceID="odsHardisk" 
                DataValueField="modelId" DataTextField="model"  Height="25px">
             <asp:ListItem Value="-1">--Choose Hardisk model--</asp:ListItem>
         </asp:DropDownList>
             <asp:ObjectDataSource ID="odsHardisk" runat="server" SelectMethod="GetHardiskModel" 
                 TypeName="ReferenceDataDirectService"></asp:ObjectDataSource>
             &nbsp;
                                                <asp:Label ID="Label2" runat="server" ForeColor="Red" Visible="False"></asp:Label>
            
         </td>
          <td style="height: 28px; width: 238px;">Hardisk size(GB)</td>
         <td style="height: 28px">
         <asp:TextBox  ID="txtHardisk" runat="server"  Width="120px" >
         </asp:TextBox>
         </td>
      </tr>
      
      <tr>
      
         <td  colspan ="2" style="height: 28px; width: 233px;">
             <asp:CheckBox ID="chkNetwork" runat="server" Text="If network card installed" 
                 AutoPostBack="True" Checked="True" 
                 oncheckedchanged="chkNetwork_CheckedChanged" />
         </td>
      </tr>
      
      <tr>
       <td style="height: 28px; width: 249px;">Network card model</td>
         <td style="height: 28px; width: 233px;">
              <asp:DropDownList ID="drlNetwork" runat="server"  Width="184px" 
                 AppendDataBoundItems="True" DataSourceID="odsNetwork" 
                 DataValueField="modelId" DataTextField="model"  Height="25px">
             <asp:ListItem Value="-1">--Choose Networkcard model--</asp:ListItem>
         </asp:DropDownList>
             <asp:ObjectDataSource ID="odsNetwork" runat="server" SelectMethod="GetNetworkCardModel" 
                 TypeName="ReferenceDataDirectService"></asp:ObjectDataSource></td>
         <td style="height: 28px; width: 238px;">Network card speed</td>
         <td style="height: 28px">
         <asp:TextBox  ID="txtNetwork" runat="server"  Width="120px" >
         </asp:TextBox>
         </td>
         
      </tr>
      
      <tr>
       <td style="height: 28px; width: 249px;">Computer name&nbsp;</td>
         <td style="height: 28px; width: 233px;">
              <asp:TextBox  ID="txtPCName" runat="server"  Width="178px" ></asp:TextBox></td>
         <td style="height: 28px; width: 238px;">IP Adress</td>
         <td style="height: 28px">
             <asp:TextBox  ID="txtIP" runat="server"  Width="120px" >
         </asp:TextBox></td>
         
      </tr>
      <tr>
         
         <td  colspan ="2" style="width: 233px; text-align:right">
            
            
             <asp:Button  ID="btnSubmit" runat="server" Text="Validate" 
              Width="71px" BorderStyle="Dotted"  
                 CssClass="btnexpress" onclick="btnSubmit_Click" ></asp:Button>
         
             
       
         </asp:Button>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
         </td>
      </tr>
     </table>
     </asp:Panel>
   
  
   </body>
</asp:Content>

